<%--
  Created by IntelliJ IDEA.
  User: dds135246
  Date: 2020/8/12
  Time: 21:14
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
</head>
<body>
<%--<h4 style="text-align: center;">退出成功，3秒后回到登录页面...</h4>--%>
</body>

<script>
    //参考网站 https://www.cnblogs.com/Stephen-GaoYu/archive/2013/04/10/3012842.html
    var hwd;
    var intSec = 3;//这里定义时间：秒
    document.write('<h4 style="text-align: center;">退出成功，<span id="pageJump">' + intSec + '</span>秒后回到登录页面…</h4>');

    function reHandle() {
        if (intSec == 0)
            window.location.href = '/user/login.jsp';
        else {
            intSec--;
            document.getElementById("pageJump").innerText = intSec;
        }
        hwd = setTimeout(reHandle, 1000);
    }

    reHandle();

</script>
</html>
